<?php session_start();
require_once('utils.php');
require_once('./content/ContentManager.php');
require_once('./content/Page.php');
$cmanager = ContentManager::getInstance();
$id = (isset($_GET['page']) && ctype_digit($_GET['page']))? $_GET['page']:1;
$pa = new Page($id);
// ADMIN
$_SESSION['admin'] = 1;


?>
<html>
<head>
	<title><?php echo $pa->getTitle(); ?></title>
	<link rel="stylesheet" type="text/css" href="./css/site.css" />
	<!--[if IE]>
		<link rel="stylesheet" type="text/css" href="./css/ie_site.css" />
	<![endif]-->
	<?php echo $cmanager->createHtmlBeginScript(); ?>
</head>
<body>
<div style="position : absolute; top=0%; left:0%; width: 20%;">
<?php 
echo $cmanager->createHtmlContent($pa->getContents()['LEFT']['id'], 'classtest');
?>
</div>
<div style="position : absolute; top=0%; left:20%; width: 60%;">
<?php 
echo $cmanager->createHtmlContent($pa->getContents()['CENTER']['id'], 'classtest');
?>
</div>
<div style="position : absolute; top=0%; right:0%; width: 20%;">
<?php 
echo $cmanager->createHtmlContent($pa->getContents()['LEFT']['id'], 'classtest');
?>
</div>		
</body>
<?php if(isAdmin){echo $cmanager->createHtmlLastScript(); } ?>

</html>

